﻿using HPIT.RentHouse.Common;
using HPIT.RentHouse.DTO;
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace HPIT.RentHouse.IService
{
    public interface IHouseService : IServiceSupport
    {
        /// <summary>
        /// 获取房源列表
        /// </summary>
        /// <param name="communityName"></param>
        /// <returns></returns>
        List<HouseDTO> GetHouseList(string communityName, int typeId, int start, int length, ref int totalCount);

        /// <summary>
        /// 获取房源附属设施
        /// </summary>
        /// <returns></returns>
        List<AttachmentDTO> GetHouseAttachments();

        /// <summary>
        /// 添加房源
        /// </summary>
        /// <param name="dto"></param>
        /// <returns></returns>
        AjaxResult AddHouse(HouseAddDTO dto);

        /// <summary>
        /// 修改房源信息
        /// </summary>
        /// <param name="dto"></param>
        /// <returns></returns>
        AjaxResult EditHouse(HouseEditDTO dto);

        HouseEditDTO GetHouse(long id);
         
        /// <summary>
        /// 添加房源图片
        /// </summary>
        /// <param name="dto"></param>
        /// <returns></returns>
        AjaxResult AddHousePics(HousePicDTO dto);
    }
}
